package com.sinosoft.weixin.utils;

import org.apache.logging.log4j.LogManager;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Service;

/**
 * Created by huzhengying on 2017/11/19.
 * 接口地址解析器
 */
public class HttpUrlUtils {
    private static org.apache.logging.log4j.Logger logger = LogManager.getLogger(HttpUrlUtils.class);

    public enum urlType{
        CheckLoginInfo,//验证登陆信息
        Test
    }

    public static String getHttpUrl(HttpUrlUtils.urlType utlType,String ip,String host){
        switch (utlType){
            case CheckLoginInfo:
                return String.format("http://%s:%s/CheckLoginInfo",ip,host);
            case Test:
                return String.format("http://%s:%s/test",ip,host);
            default:return null;
        }
    }

}
